<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>课程信息</title>
	<meta name="decorator" content="default" />
	<script type="text/javascript">
		function can(){
            var k=$("input[type='checkbox']:checked").length;
            if (k<=0) return "";
            else {
                var chk_value =[];
                $('input[name="courseId"]:checked').each(function(){
                    chk_value.push($(this).val());
                });
                return  chk_value;
            }
		}
		function clsCheckbox(){
            $("[name = courseId]:checkbox").attr("checked", false);
		}
        function page(n, s) {
            $("#pageNo").val(n);
            $("#pageSize").val(s);
            $("#searchForm").submit();
            return false;
        }
	</script>
</head>
<body>
<table id="contentTable" class="table table-striped table-bordered table-condensed">
	<thead>
	<tr>
		<th></th>
		<th>课程序号</th>
		<th>课程名称</th>
		<th>课程介绍</th>
		<th>是否免费</th>
		<th>课程原价</th>
		<th>课程现价</th>
		<shiro:hasPermission name="business:course:edit">
			<th>操作</th>
		</shiro:hasPermission>
	</tr>
	</thead>
	<tbody>
	<c:forEach items="${courseVOList}" var="course">
		<tr>
			<td>${course.id}</td>
			<td>${course.seq}</td>
			<td>${course.title}</td>
			<td>${course.introduction}</td>
			<td>${dic:getLabelByValue(course.free, 'course_if_free')}</td>
			<td>${course.originalPrice}</td>
			<td>${course.presentPrice}</td>
			<td> <input id="courseId" name="courseId" type="checkbox" value="${course.id}"></td>
		</tr>
	</c:forEach>
	</tbody>
</table>
<div class="pagination">${page}</div>
</body>
</html>